home *** CD-ROM | disk | FTP | other *** search
/ Aminet 1 (Walnut Creek) / Aminet - June 1993 [Walnut Creek].iso / aminet / misc / amag / 9303b.lha / Inside Amos / Listings / Fonts.asc next >
Text File  |  1993-02-25  |  716b  |  40 lines

  1. ' FONTS Unterroutinen
  2. '
  3. ' Zunächst einmal dimensionieren
  4. '
  5. Dim _FONTNAME$(100),_GROESSE(100)
  6. '
  7. ' Variable als global setzen.
  8. '
  9. Global _FONTNAME$(),_GROESSE()
  10. '
  11. ' Jetzt kann man die Fonts einlesen und einen
  12. ' gewünschten Font anzeigen lassen !
  13. _LESE_FONTS
  14. _FONT["Diamond",20]
  15. '
  16. Procedure _LESE_FONTS
  17.    Get Fonts
  18.    I=0
  19.    While 1
  20.       Inc I
  21.       A$=Font$(I)
  22.       If A$-" "="" Then Exit
  23.       A$=Upper$(A$)
  24.       _FONTNAME$(I)=Left$(A$,29)-" "
  25.       _GROESSE(I)=Val(Mid$(A$,30,3))
  26.    Wend
  27.    Dec I
  28. End Proc
  29. Procedure _FONT[N$,G]
  30.    N$=Upper$(N$)
  31.    NUMMER=0
  32.    For I=1 To 100
  33.       If(N$=_FONTNAME$(I)) and(G=_GROESSE(I))
  34.          Set Font I
  35.          NUMMER=I
  36.          Exit
  37.       End If
  38.    Next I
  39. End Proc[NUMMER]
  40.